package cn.itsource.basic.mapper;

import cn.itsource.basic.query.BaseQuery;

import java.util.List;

public interface BaseMapper<T> {

    void save(T t);

    void delete(Long id);

    void update(T t);

    T loadById(Long id);

    List<T> loadAll();

    /*下面两个是分页查询所需方法*/
    /*查询总条数*/
    Integer queryCount(BaseQuery query);
    /*查询当前页的数据*/
    List<T> queryData(BaseQuery query);

    void bulkRemove(List<Long> ids);
}
